import { View } from "@tarojs/components";
import style from "./index.module.scss";

export type CagegoryTagProps = {
  categoryName: string;
  size?: "default" | "small";
  themeColor?: string;
};

const CategoryTag = ({
  categoryName,
  size = "default",
  themeColor,
}: CagegoryTagProps) => {
  return (
    <View
      className={`${style["category-tag"]} category-tag-${size} `}
      style={{ backgroundColor: themeColor }}
    >
      {categoryName}
    </View>
  );
};

export default CategoryTag;
